﻿using System.Windows.Data;

using iStudio.Library;
using iStudio.Structure.Control.Audio.TimeSelector;
using iStudio.Structure.Engine;

namespace iStudio.Control.Audio
{
    /// <summary>
    /// Interaction logic for SelectionControl.xaml
    /// </summary>
    public partial class SelectionControl
    {
        public SelectionControl()
        {
            InitializeComponent();

            AudioEngine soundEngine = AudioEngine.Instance;

            UiHelper.Bind (soundEngine, "SelectionBegin", selectionStart, TimeSelector.ValueProperty, BindingMode.TwoWay);
            UiHelper.Bind (soundEngine, "SelectionEnd", selectionEnd, TimeSelector.ValueProperty, BindingMode.TwoWay);
        }
    }
}
